<template>
  <div>
    <base-page
      url="/api/user/list"
      downloadUrl="http://www.baidu.com"
      importUrl="/user/save/img"
      :gridColumns="columns"
      rowKey="id"
      :queryParams="params"
      :editClick="edit"
      :multiple="false"
      :operating="['query','new','edit','delete','download','import']"
      :downloadClick="dc"
      :queryOptions="queryOptions"
      :queryForm="queryForm"
      :queryColNum="4"
    />
    
  </div>
</template>

<script>
import BasePage from '../../components/base/BasePage.vue';
export default {
  components: { BasePage },
  data() {
    return {
      queryOptions:{roleName:{type:'select',label:'角色名称',multiple:true},description:'cascader',createBy:'text',createTime:'datetime'},
      queryForm:{roleName:[1,2],description:'150302',createBy:'',createTime:''},
      params: {},
      columns: [
        { prop: "roleName", label: "角色名称", dictName: "test", width:200 },
        {
          prop: "description",
          label: "部门",
          dictName: "行政区划",
          width: 200,
        },
        { prop: "createBy", label: "创建人", width: 100 },
        {
          prop: "createTime",
          label: "创建时间",
          format: "YYYY-MM-DD HH:mm:ss",
          width: 200,
        },
        { prop: "updateBy", label: "更新人", width: 100 },
        {
          prop: "updateTime",
          label: "更新时间",
          format: "YYYY-MM-DD HH:mm:ss",
          width: 200,
        },
        { prop: "age", label: "年龄", width: 60 },
      ],
    };
  },
  methods:{
    edit(index,row){
      console.log('edit',index,row)
    },
    dc(url){
      window.open("http://www.whga.cn")
    }
  }
};
</script>
